<!DOCTYPE html>
<html>
<head>
    <meta name="layout" content="main"/>
    <g:set var="entityName" value="${message(code: 'user.label', default: 'user')}"/>
    <title>企业固定资产</title>
    <style>
    .table>tbody>tr>td{
        vertical-align: middle;
    }
    </style>
</head>

<body class="fixed-navbar fixed-sidebar">
<div class="small-header">
    <div class="hpanel">
        <div class="panel-body">
            <div id="hbreadcrumb" class="pull-right">
                <ol class="hbreadcrumb breadcrumb">
                    <li>贷款管理系统</li>
                    <li class="active">
                        <span>企业固定资产</span>
                    </li>
                </ol>
            </div>

            <h2 class="font-light m-b-xs">
                企业固定资产
            </h2>
            <small><span class="glyphicon glyphicon-cog" aria-hidden="true"></span> 所有企业固定资产</small>
        </div>
    </div>
</div>

<div class="content animate-panel">

    <div class="row">
        <g:if test="${flash.message}">
            <div class="message alert alert-info" role="status">${flash.message}
                <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span
                        aria-hidden="true">×</span></button>
            </div>
        </g:if>
        <g:form method="POST" action="index">
            <div class="hpanel hblue">
                <div class="panel-heading">
                    <div class="panel-tools">
                        <button class="btn btn-primary btn-xs" type="submit"><i class="fa fa-search"></i>查询</button>
                        <button class="btn btn-warning2 btn-xs" type="button" id="resetBtn"><i
                                class="fa fa-times"></i>重置</button>
                    </div>
                    查询
                </div>

                <div class="panel-body">
                    <div class="col-sm-3">
                        <input type="text" class="form-control" placeholder="企业名称" name="account" id="account"
                               value="${params?.account}">
                    </div>
                </div>
            </div>
        </g:form>
    </div>

    <div class="row">
        <div class="hpanel hgreen">
            <div class="panel-heading">
                <div class="panel-tools">
                    <g:link action="create" class="btn btn-info btn-xs"><i class="fa fa-plus"></i>新建</g:link>
                    <a class="showhide"><i class="fa fa-chevron-up"></i></a>
                </div>
                企业固定资产
            </div>

            <div class="panel-body">
                <div class="table-responsive">
                    <table class="table table-striped table-bordered table-hover">
                        <thead>
                        <tr>
                            <g:sortableColumn property="certificate"
                                              title="${message(code: 'user.username.label', default: '权利证书号')}"/>
                            <g:sortableColumn property="currencyType"
                                              title="${message(code: 'user.fullName.label', default: '币种')}"/>
                            <g:sortableColumn property="valuationDate"
                                              title="${message(code: 'user.department.label', default: '评估日期')}"/>
                            <g:sortableColumn property="valuationProvider"
                                              title="${message(code: 'user.position.label', default: '评估机构')}"/>
                            <g:sortableColumn property="totalPrice"
                                              title="${message(code: 'user.code.label', default: '资产净值')}"/>
                            <g:sortableColumn property="name"
                                              title="${message(code: 'user.externalId.label', default: '固定资产名称')}"/>
                            <g:sortableColumn property="status"
                                              title="${message(code: 'user.account.label', default: '资产状态')}"/>

                            <g:sortableColumn property="type"
                                              title="${message(code: 'user.enabled.label', default: '资产类型')}"/>
                            <g:sortableColumn property="appliedTotalPrice"
                                              title="${message(code: 'user.accountExpired.label', default: '入账价值')}"/>
                            <g:sortableColumn property="modifiedDate"
                                              title="${message(code: 'user.accountLocked.label', default: '更新日期')}"/>
                        </tr>
                        </thead>
                        <tbody>
                        <g:each in="${propertyInformationList}">
                            <tr>
                                <td><g:link action="show" id="${it?.id}"
                                            class="firstTd nameFormat">${it?.certificate?.serialNumber}</g:link></td>
                                <td>${it?.currencyType?.name}</td>
                                <td>${it?.valuationDate}</td>
                                <td>${it?.valuationProvider?.name}</td>
                                <td>${it?.totalPrice}</td>
                                <td>${it?.name}</td>
                                <td>${it?.status}</td>
                                <td>${it?.type?.name}</td>
                                <td>${it?.appliedTotalPrice}</td>
                                <td>${it?.modifiedDate}</td>
                            </tr>
                        </g:each>
                        </tbody>
                    </table>
                </div>
            </div>

            <div class="panel-footer">
                <div class="pagination">
                    <g:paginate total="${propertyInformationCount ?: 0}" params="${params}"/>
                </div>
            </div>
        </div>
    </div>
</div>
<g:javascript>
    $(function () {
        $("#resetBtn").click(function () {
            $("#account").val("");
        })
    });

</g:javascript>
</body>
</html>
